package com.xhsj.user.hr.system.mapper;

import org.apache.ibatis.annotations.Mapper;
import com.xhsj.user.hr.system.entity.TbHrUserSocialSecurity;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;
/**
 * <p>
 * 用户社保凭证表 Mapper 接口
 * </p>
 *
 * @author suxiaolin
 * @since 2021-08-05
 */
@Mapper
public interface TbHrUserSocialSecurityMapper extends BaseMapper<TbHrUserSocialSecurity> {

    /**
     * 获取用户社保凭证
     * @author 苏小林
     * @date 2021/8/6 9:42
     * @param: userId
     * @return: com.xhsj.user.hr.system.entity.TbHrUserSocialSecurity
     */
    TbHrUserSocialSecurity getUserSocialSecurity(@Param("userId") Long userId);

    /**
     * 通过用户id 修改数据
     * @author 苏小林
     * @date 2021/8/6 16:34
     * @param: entity
     */
    void updateByUserId(@Param("entity") TbHrUserSocialSecurity entity);

    void delByUserId(@Param("userId") Long userId);

    void updateUseNum(@Param("id") Long id, @Param("sum") int sum);
}
